package patrol.mobile.com.mobilepatrol.activity.security.adapter;

import android.content.Context;
import android.view.View;

import com.dl7.recycler.adapter.BaseQuickAdapter;
import com.dl7.recycler.adapter.BaseViewHolder;

import patrol.mobile.com.mobilepatrol.R;
import patrol.mobile.com.mobilepatrol.bean.ProtectListBooksBean;

/**
 * Created by admin on 2018/9/9.
 */

public class EmergencyProtectAdapter extends BaseQuickAdapter<ProtectListBooksBean> {


    public EmergencyProtectAdapter(Context context) {
        super(context);
    }

    @Override
    protected int attachLayoutRes() {
        return R.layout.item_emergency_protect_list;
    }

    @Override
    protected void convert(final BaseViewHolder holder, ProtectListBooksBean item) {
        holder.setText(R.id.tv_num, (holder.getLayoutPosition()) + "");
        holder.setText(R.id.tv_captainName, item.getCaptainName());
        holder.setText(R.id.tv_name, item.getName());
        holder.setText(R.id.tv_sex, item.getSex());
        holder.setText(R.id.tv_nation, item.getNation());
        holder.setText(R.id.tv_jobPosition, item.getJobPosition());
        holder.setText(R.id.tv_teamDuty, item.getTeamType());
        holder.setText(R.id.tv_phone, item.getPhone());


    }
}
